package com.xuezhixin.example.web.serviceImple;

import java.util.ArrayList;
import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.xuezhixin.example.web.dao.ClassmateMapper;
import com.xuezhixin.example.web.model.ClassMate;
import com.xuezhixin.example.web.service.ClassMateService;

@Service("ClassMateServiceImpl")
public class ClassMateServiceImpl  implements ClassMateService{

	@Resource
	ClassmateMapper classmateMapper;
	
	
	public List<ClassMate> selectList() {
		ArrayList<ClassMate> classMateList=new ArrayList<ClassMate>();
		ClassMate classMate=new ClassMate();
		ClassMate classMate2=new ClassMate();
		
		classMate.setUserName("kf");
		classMate.setPassword("123");
		classMate2.setUserName("test");
		classMate2.setPassword("456");
		classMateList.add(classMate);
		
		classMateList.add(classMate2);
		return classMateList;
	}

	
	
	public List<ClassMate> selectListDB() {
		// TODO Auto-generated method stub
		 List<ClassMate>   classMateList= classmateMapper.selectListDB();
		return classMateList;
	}

	
}
